package com.ruoyi.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.common.core.domain.entity.HomeBanner;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author linxz
 * @since 2025-01-02
 */
@Mapper
public interface HomeBannerMapper extends BaseMapper<HomeBanner> {

    List<HomeBanner> getList();

    int addEntity(HomeBanner homeBanner);

    int updateEntity(HomeBanner homeBanner);

    int delete(@Param("id") int id);

    List<String>  selectCategoryList();

    List<String> selectSectionListByCategory(@Param("category") String category);

    List<HomeBanner> getListBySection(@Param("category")String category,@Param("sectionName")String sectionName);

    List<String> getBannerSectionList();

    List<Integer> getBannerIdList(@Param("sectionName")String sectionName);

    List<HomeBanner> getBannerById(@Param("id") int id);

}
